/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package jp.co.irep.juten.entity;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.validation.constraints.NotNull;
import javax.xml.bind.annotation.XmlRootElement;

/**
 *
 * @author toan_nguyen
 */
@Entity
@Table(name = "claim_item_tbl")
@XmlRootElement
@NamedQueries({
    @NamedQuery(name = "ClaimItemTbl.findAll", query = "SELECT c FROM ClaimItemTbl c"),
    @NamedQuery(name = "ClaimItemTbl.findByManageNo", query = "SELECT c FROM ClaimItemTbl c WHERE c.manageNo = :manageNo"),
    @NamedQuery(name = "ClaimItemTbl.findByCatalogNo", query = "SELECT c FROM ClaimItemTbl c WHERE c.catalogNo = :catalogNo"),
    @NamedQuery(name = "ClaimItemTbl.findByFormCategory", query = "SELECT c FROM ClaimItemTbl c WHERE c.formCategory = :formCategory"),
    @NamedQuery(name = "ClaimItemTbl.findByMakerNo", query = "SELECT c FROM ClaimItemTbl c WHERE c.makerNo = :makerNo"),
    @NamedQuery(name = "ClaimItemTbl.findByDelivery", query = "SELECT c FROM ClaimItemTbl c WHERE c.delivery = :delivery"),
    @NamedQuery(name = "ClaimItemTbl.findById", query = "SELECT c FROM ClaimItemTbl c WHERE c.id = :id")})
public class ClaimItemTbl implements Serializable {
    private static final long serialVersionUID = 1L;
    @Basic(optional = false)
    @NotNull
    @Column(name = "manage_no")
    private long manageNo;
    @Basic(optional = false)
    @NotNull
    @Column(name = "catalog_no")
    private int catalogNo;
    @Basic(optional = false)
    @NotNull
    @Column(name = "form_category")
    private short formCategory;
    @Basic(optional = false)
    @NotNull
    @Column(name = "maker_no")
    private int makerNo;
    @Basic(optional = false)
    @NotNull
    @Column(name = "delivery")
    private int delivery;
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Basic(optional = false)
    @Column(name = "id")
    private Long id;

    public ClaimItemTbl() {
    }

    public ClaimItemTbl(Long id) {
        this.id = id;
    }

    public ClaimItemTbl(Long id, long manageNo, int catalogNo, short formCategory, int makerNo, int delivery) {
        this.id = id;
        this.manageNo = manageNo;
        this.catalogNo = catalogNo;
        this.formCategory = formCategory;
        this.makerNo = makerNo;
        this.delivery = delivery;
    }

    public long getManageNo() {
        return manageNo;
    }

    public void setManageNo(long manageNo) {
        this.manageNo = manageNo;
    }

    public int getCatalogNo() {
        return catalogNo;
    }

    public void setCatalogNo(int catalogNo) {
        this.catalogNo = catalogNo;
    }

    public short getFormCategory() {
        return formCategory;
    }

    public void setFormCategory(short formCategory) {
        this.formCategory = formCategory;
    }

    public int getMakerNo() {
        return makerNo;
    }

    public void setMakerNo(int makerNo) {
        this.makerNo = makerNo;
    }

    public int getDelivery() {
        return delivery;
    }

    public void setDelivery(int delivery) {
        this.delivery = delivery;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (id != null ? id.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof ClaimItemTbl)) {
            return false;
        }
        ClaimItemTbl other = (ClaimItemTbl) object;
        if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "jp.co.irep.tech.juten.jpa.entity.ClaimItemTbl[ id=" + id + " ]";
    }
    
}
